﻿using HAOest.Diandi.Model;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace HAOest.DianDi.UI.Control
{
    /// <summary>
    /// NoteListControl.xaml 的交互逻辑
    /// </summary>
    public partial class NoteListControl : UserControl
    {
        public NoteListControl()
        {
            InitializeComponent();
        }

        public void LoadNoteList()
        {
            NoteItem noteItem = new NoteItem();
            noteItem.Id = 1;
            noteItem.ContentText = "【中国有没有特赦？】8月8日，泰国国会对特赦法草案进行一读投票并通过。8月15日，韩国光复节，总统朴槿惠遵守大选时“限制行使赦免权”的承诺，不进行特赦。其实，世界上很多国家都有特赦制度，例如美国、俄罗斯、越南等，那么中国有特赦吗？特赦和大赦又有什么区别？";
            noteItem.Date = DateTime.Now;
            NoteItemControl noteItemControl = new NoteItemControl(noteItem);
            NoteItemControl noteItemControl2 = new NoteItemControl(noteItem);
            NoteItemControl noteItemControl3 = new NoteItemControl(noteItem);
            listChildrenStackPanel.Children.Add(noteItemControl);
            listChildrenStackPanel.Children.Add(noteItemControl2);
            listChildrenStackPanel.Children.Add(noteItemControl3);
        }
    }
}
